<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>

<body>num
  <script>
    const obj1 = { a: 1, b: 2 }

    const obj2 = obj1;
    const obj3 = { ...obj1 ,c:3}
    // const obj3 = { a:1,b:2,c:3,d:4 }

    console.log(obj2);
    console.log(obj3);
  </script>
</body>

</html>